# entity 实体，所有的类都在这定义
class User:
    count = 0
# class 属性attribute
#     def __init__(self,name,age,sex):
#         self.name = name
#         self.age = age
#         self.sex = sex
    def __init__(self,name,age=None,sex=None,email=None):
        self.__name = name
        self.age = age
        self.sex = sex
        self.email = email
        # private attribute
    def __myprint(self):
        print("my name is")

    def setName(self,name):
        self.__name = name

    def getName(self):
        return self.__name

    def __show(self):
        print("show ----")
        self.myprint()



    @classmethod
    def show2(cls):
        print("classmethod ----")

    @staticmethod
    def show3(str1,str2):
        print(f"staticmethod -{str1}--{str2}-")

class Parent:
    name = 'parent'
    def __init__(self):
        self.name = "parent"

    def show1(self):
        print(f"parent --{self.name}--")

# 继承用小括号Inheritance is in parentheses
class Child(Parent):
    sub_name = 'child'
    def show1(self):
        print(f"parent --{self.sub_name}--")

class Son(Parent):
    name = 'son'
    def show1(self):
        print(f"Son --{self.name}--")